package com.kob.design.builder;

/**
 * @Description: 抽象构建者
 * @Author: fyt
 * @Date: 2024/4/16 9:43
 **/
public abstract class Builder {
    protected Bike bike = new Bike();

    public abstract void builderFrame();

    public abstract void builderSeat();

    public abstract Bike createBike();

    // 如果construct过于复杂,还是封装到Director
    public Bike construct() {
        this.builderFrame();
        this.builderSeat();
        return this.createBike();
    }
}
